package com.icare.common.service.properties;

import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.Configuration;

/**
 * 描述:
 * 创建者:田海波 于 2018年06月01日 10:17.
 */
@Configuration
@ConditionalOnProperty(prefix = "redis.config" ,value = "nodes")
@ConfigurationProperties(prefix = "redis.config")
public class RedisProperties {

    private String nodes;

    private Integer maxRedirects;

    private String password;

    private Integer timeout;

    private Integer maxTotal;

    private Integer db;

    private String clusterOrSentinel;

    private String sentinelMaster;

    public String getNodes() {
        return nodes;
    }

    public void setNodes(String nodes) {
        this.nodes = nodes;
    }

    public Integer getMaxRedirects() {
        return maxRedirects;
    }

    public void setMaxRedirects(Integer maxRedirects) {
        this.maxRedirects = maxRedirects;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Integer getTimeout() {
        return timeout;
    }

    public void setTimeout(Integer timeout) {
        this.timeout = timeout;
    }

    public Integer getMaxTotal() {
        return maxTotal;
    }

    public void setMaxTotal(Integer maxTotal) {
        this.maxTotal = maxTotal;
    }

    public Integer getDb() {
        return db;
    }

    public void setDb(Integer db) {
        this.db = db;
    }

    public String getClusterOrSentinel() {
        return clusterOrSentinel;
    }

    public void setClusterOrSentinel(String clusterOrSentinel) {
        this.clusterOrSentinel = clusterOrSentinel;
    }

    public String getSentinelMaster() {
        return sentinelMaster;
    }

    public void setSentinelMaster(String sentinelMaster) {
        this.sentinelMaster = sentinelMaster;
    }
}
